package cn.lanqiao.springboot.mapper;

import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

@Repository
public interface RoleMenuMapper {

    @Insert("insert into system_role_menu (role_id, menu_id) values (#{roleId}, #{menuId})")
    void insert(@Param("roleId") Integer roleId, @Param("menuId") Integer menuId);

    @Delete("delete from system_role_menu where role_id = #{roleId}")
    void delete(Integer roleId);
}
